module.exports = (req, res, next) => {
  const query = {};
  const body = {};
  for (const key in req.query) {
    if (req.query[key] !== '') {
      query[key] = req.query[key];
    }
  }
  for (const key in req.body) {
    if (req.body[key] !== '') {
      body[key] = req.body[key];
    }
  }
  req.query = query;
  req.body = body;
  next();
};
